program PointInFigure;

{$APPTYPE CONSOLE}
var
x, y : array of real;
n, i  : integer;
fin : textfile;
xo, yo : real;
sum, sum2 : real;
s : real;
begin
  assignfile(fin, 'input.txt');
  reset(fin);
  readln(fin, n);
  readln(fin, xo, yo);
  setlength(x, n);
  setlength(y, n);
  for i := 1 to n do
  begin
    if (i mod 2 <> 0) then
    begin
      read(fin, x[i]);
    end
    else
      read(fin, y[i-1]);
  end;
  for i:=1 to n-2 do
  begin
    s := (x[1]-x[i+2])*(y[i+1]-y[i+2])-(x[i+1]-x[i+2])*(y[1]-y[i+2]);
    sum := sum+abs(s);
  end;
  for i:=0 to n-2 do
  begin
    s := (xo-x[i+2])*(y[i+1]-y[i+2])-(x[i+1]-x[i+2])*(yo-y[i+2]);
    sum2 := sum2 + abs(s);
  end;
  if (sum = sum2) then writeln('yes');
  if (sum <> sum2) then writeln('no');
end.
